﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace C4Tools
{
    static class Constants
    {
        static public string DimmerCmdTemplate = @"
  <c4soap name='SendToDeviceAsync' async='False'>
    <param name='iddevice' type='number'>{0}</param>
    <param name='data' type='string'>
      <devicecommand owneridtype='' owneriditem='-1'>
        <command>SET_LEVEL</command>
        <params>
          <param>
            <name>LEVEL</name>
            <value type='INTEGER'>
              <static>{1}</static>
            </value>
          </param>
        </params>
      </devicecommand>
    </param>
  </c4soap>";

        static public string GetMovieDetailsTemplate = @"
  <c4soap name='SendToDevice'>
    <param name='iddevice' type='number'>{0}</param>
    <param name='data' type='string'>
      <devicecommand>
        <command>GET_VIDEO_MEDIA</command>
        <params>
          <param>
            <name>type</name>
            <value type='STRING'>
              <static>MOVIE_INFO</static>
            </value>
          </param>
          <param>
            <name>idmedia</name>
            <value type='STRING'>
              <static>{1}</static>
            </value>
          </param>
        </params>
      </devicecommand>
    </param>
  </c4soap>";

        static public string GetItemsCmdTemplate = @"
  <c4soap name='GetItems' async='False'>
    <param name='filter' type='number'>{0}</param>
  </c4soap>";

        static public string GetMoviesCmdTemplate = @"
  <c4soap name='GetMediaByDevice' session='0' async='False'>
    <param name='iddevice' type='number'>{0}</param>
    <param name='type' type='string'>MOVIE</param>
  </c4soap>";

        static public string SimpleCmdTemplate = @"
  <c4soap name='SendToDeviceAsync' async='False'>
    <param name='iddevice' type='number'>{0}</param>
    <param name='data' type='string'>
      <devicecommand owneridtype='' owneriditem='-1'>
        <command>{1}</command>
      </devicecommand>
    </param>
  </c4soap>";

        static public string ControlCmdTemplate = @"
  <c4soap name='SendToDeviceAsync' async='False'>
    <param name='iddevice' type='number'>{0}</param>
    <param name='data' type='string'>
      <devicecommand>
        <command>{1}</command>
        <params></params>
      </devicecommand>
    </param>
  </c4soap>";


        static public string SelectMediaTemplate = @"
  <c4soap name='SendToDevice' async='False'>
    <param name='iddevice' type='number'>{0}</param>
    <param name='data' type='string'>
      <devicecommand>
        <command>SELECT_VIDEO_MEDIA</command>
        <params>
          <param>
            <name>mediaid</name>
            <value type='string'>
              <static>{1}</static>
            </value>
          </param>
          <param>
            <name>type</name>
            <value type='string'>
              <static>MOVIE</static>
            </value>
          </param>
        </params>
      </devicecommand>
    </param>
  </c4soap>";


        static public string SelectVideoDeviceTemplate = @"
  <c4soap name='SendToDevice' async='False'>
    <param name='iddevice' type='number'>{0}</param>
    <param name='data' type='string'>
      <devicecommand>
        <command>SELECT_VIDEO_DEVICE</command>
        <params>
          <param>
            <name>deviceid</name>
            <value type='INT'>
              <static>{1}</static>
            </value>
          </param>
          <param>
            <name>devicegroup</name>
            <value type='STRING'>
              <static>watch</static>
            </value>
          </param>
        </params>
      </devicecommand>
    </param>
  </c4soap>";


    }
}
